<template>
  <div id="app">
    <h1>{{str}}</h1>
    <button @click="aa">反转</button>
  </div>
</template>

<script>
export default {
  name: "App",
  data() {
    return {
      str: "hello world",
    };
  },
  methods:{
    aa(){
      this.str=this.str.split('').reverse().join('')
    }
  }
};
</script>

<style>
</style>